import java.util.Scanner;
public class 测试 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        System.out.print("Please input password:");
        String x=input.next();
        detect(x);
    }
    public static void detect(String x) {
        if(x.length()>=8) {
            if(!(isDigit(x)&&isZm(x)))
                System.out.println("InValid Password.");
            else if(isDigit(x))
                System.out.println("Valid Password.");
        }
        else
            System.out.println("Invalid Password.");
    }
    public static boolean isDigit(String x) {
        int j=0;
        for(int i=0;i<x.length();i++) {
            if(Character.isDigit(x.charAt(i)))
                j+=1;
        }
        return j >= 2;
    }
    public static boolean isZm(String x) {
        for(int i=0;i<x.length();i++) {
            if(Character.isLetter(x.charAt(i)))
                return true;
        }
        return false;
    }
}